#!/usr/bin/env bash
# SPDX-License-Identifier: BSD-3-Clause
# Copyright 2015-2019, Intel Corporation

#
# src/test/blk_rw/TEST8 -- unit test for pmemblk_read/write/set_zero/set_error
#

. ../unittest/unittest.sh

require_test_type medium
exclude_ppc64

# doesn't make sense to run in local directory
require_fs_type pmem non-pmem

setup

require_free_space 2G

create_poolset $DIR/testset1 1G:$DIR/testfile1:x 1G:$DIR/testfile2:x

expect_normal_exit ./blk_rw$EXESUFFIX 512 $DIR/testset1 c\
	w:0 w:1 r:1 r:0\
	w:4161445 r:4161445

check_pool $DIR/testfile2

check

pass
